package com.csun.cmny.provider.controller.admin;

import com.csun.cmny.provider.resolver.CmnyMessageSource;
import com.csun.cmny.util.wrapper.WrapMapper;
import com.csun.cmny.util.wrapper.Wrapper;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * @Auther: chisj chisj@foxmal.com
 * @Date: 2020-01-18 10:21
 * @Description:
 */
@RestController
@RequestMapping(value = "/auth")
public class MdcAuthController {

    @Resource
    private CmnyMessageSource cmnyMessageSource;

    @PostMapping(value = "/throwExec")
    public Wrapper throwExec(Integer result, Long groupId, String code) {

        return WrapMapper.wrap(Wrapper.SUCCESS_CODE, cmnyMessageSource
                .getMessage("operation.success", null));
    }

}
